package cnhy.salary.domain;

import cnhy.salary.domain.proxy.EmployeeProxy;
import com.easy.query.core.enums.RelationTypeEnum;
import com.easy.query.core.proxy.ProxyEntityAvailable;
import com.fasterxml.jackson.annotation.JsonFormat;
import com.ruoyi.common.annotation.Excel;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import java.io.Serializable;
import java.util.Date;
import lombok.Data;
import com.easy.query.core.annotation.*;
import ling.common.domain.entity.*;

import javax.validation.constraints.NotBlank;
import javax.validation.constraints.NotNull;

/**
 * 员工;
 * @author : He-LiangLiang@Outlook.com
 * @date : 2025-5-26
 */
@ApiModel(value = "员工",description = "")
@EntityProxy
@Table("pay_employee")
@Data
public class Employee extends CreatedEntity.LongId implements IDeptEntity, Serializable,Cloneable, ProxyEntityAvailable<Employee , EmployeeProxy> {
    /**  */
    /*
    @Excel(name = "员工名称", type = Excel.Type.EXPORT, cellType = Excel.ColumnType.NUMERIC, prompt = "用户编号")
    @Column(primaryKey = true)
    @ApiModelProperty(value = "",notes = "")
    private Long id ;
    */
    
    /** 员工名称 */
    @Excel(name = "员工名称")
    @EasyWhereCondition
    @ApiModelProperty(value = "员工名称",notes = "")
    @NotBlank
    private String name ;
     
   
    /** 系统账号id,无则为null */
    @EasyWhereCondition(type = EasyWhereCondition.Condition.EQUAL)
    @ApiModelProperty(value = "系统账号id,无则为null",notes = "")
    private Long userId ;

     @ColumnIgnore
    @Navigate(value = RelationTypeEnum.OneToOne, selfProperty = {"userId"}, targetProperty = {"userId"})
    UserRef user;

    @Excel(name = "部门id",type = Excel.Type.IMPORT)
     @EasyWhereCondition(type = EasyWhereCondition.Condition.EQUAL)
     @ApiModelProperty(value = "系统账号deptId",notes = "")
    Long deptId;

   
    /** 工号 */
    @Excel(name = "工号",type = Excel.Type.EXPORT)
    @EasyWhereCondition
    @ApiModelProperty(value = "工号",notes = "")

    private String jobNum ;
     
   
    /** 手机 */
    @Excel(name = "手机")
    @EasyWhereCondition
    @ApiModelProperty(value = "手机",notes = "")
    @NotBlank
    private String phone ;
     
   
    /** 身份证 */
    @Excel(name = "身份证")
    @EasyWhereCondition
    @ApiModelProperty(value = "身份证",notes = "")
    private String code ;
     
   
    /** 银行卡号 */
    @Excel(name = "银行卡")
    @EasyWhereCondition
    @ApiModelProperty(value = "银行卡号",notes = "")
    private String bankCard ;
     
   
    /** 银行名称 */
    @Excel(name = "银行名称")
    @ApiModelProperty(value = "银行名称",notes = "")
    @EasyWhereCondition
    private String bankName ;
     
   
    /** 入职日期 */
    @Excel(name = "入职日期",dateFormat ="yyyy-MM-dd")
    @ApiModelProperty(value = "入职日期",notes = "")
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    @EasyWhereCondition(type = EasyWhereCondition.Condition.GREATER_THAN_EQUAL)
    @NotNull
    private Date entryTime ;

     @ApiModelProperty(value = "入职日期2-查询",notes = "")
     @ColumnIgnore
     @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
     @EasyWhereCondition(type = EasyWhereCondition.Condition.LESS_THAN_EQUAL, propName = "entryTime")
     private Date entryTime2 ;
   
    /** 岗位id */
    @Excel(name = "岗位id",type = Excel.Type.IMPORT)
    @ApiModelProperty(value = "岗位id",notes = "")
    private Long post ;
     
   
    /** 岗位名称 */
    @Excel(name = "岗位名称")
    @ApiModelProperty(value = "岗位名称",notes = "")
    private String postName ;
     
   
    /** 调换岗位 */
    @ApiModelProperty(value = "副岗位",notes = "")
    private Long tempPost ;
     
   
    /** 调换岗位名称 */
    @ApiModelProperty(value = "副岗位名称",notes = "")
    private String tempPostName ;

     @ApiModelProperty(value = "副岗位部门",notes = "")
    Long tempDept;
     /** 调岗开始时间 */
     @ApiModelProperty(value = "调岗开始时间",notes = "")
     private Date tempBegin ;
   
    /** 生日 */
    @Excel(name = "生日",dateFormat ="yyyy-MM-dd")
    @ApiModelProperty(value = "生日",notes = "")
    private Date birthday ;
     
   
    /** 0男，1女 */
    @Excel(name = "性别",readConverterExp = "0=男,1=女")
    @ApiModelProperty(value = "0男，1女",notes = "")
    private Integer sex ;
     
   
    /** 推荐人 */
     @Excel(name = "推荐人")
    @ApiModelProperty(value = "推荐人",notes = "")
    private String referrer ;
     @Excel(name = "推荐人电话")
     @ApiModelProperty(value = "推荐人电话",notes = "")
     private String referrerPhone ;
   
    /** 离职时间 */
    @Excel(name = "离职时间",dateFormat ="yyyy-MM-dd" ,type = Excel.Type.EXPORT)
    @ApiModelProperty(value = "离职时间",notes = "")

    private Date resignTime ;

    @ColumnIgnore
    Integer resign;

    /** 外部标识 */
    @ApiModelProperty(value = "外部标识",notes = "")
    private String sign ;

    /** 排序 */
    @Excel(name = "排序",type = Excel.Type.IMPORT)
    @ApiModelProperty(value = "排序",notes = "")
    private Integer orderNum;

}